﻿#region Using directives

using System;
using System.Collections.Generic;
using System.Text;

#endregion

namespace Weazel.Gezel.Model.Errors
{
  /// <summary>
  /// Enumerates the various types of verification errors.
  /// </summary>
  public enum VerificationErrorType
  {
    /// <summary>
    /// The design is empty (no ipblocks, controllers, dps..)
    /// </summary>
    EmptyDesign,

    /// <summary>
    /// Only use this error type during early development
    /// </summary>
    UnspecifiedError,

    /// <summary>
    /// Controller has no transitions
    /// </summary>
    ControllerNoTransitions,

    /// <summary>
    /// Controller lacks an initial state
    /// </summary>
    ControllerNoInitialState,

    /// <summary>
    /// Source state of transition not declared
    /// </summary>
    ControllerUndeclaredSourceState,

		/// <summary>
		/// Target state of transition not declared
		/// </summary>
		ControllerUndeclaredTargetState,

    /// <summary>
    /// The datapath to control is unknown
    /// </summary>
    ControllerUnknownDatapath,

    /// <summary>
    /// The signalflowgraph referenced
    /// in controller is unknown
    /// </summary>
    ControllerUnknownSfg,

    /// <summary>
    /// Hardwired controller references
    /// multiple signalflowgraphs
    /// </summary>
    ControllerMultipleSfg,

    /// <summary>
    /// Controller references no 
    /// signalflowgraphs
    /// </summary>
    ControllerNoSfg,

    /// <summary>
    /// An fsm controller without transitions
    /// </summary>
    ControllerFsmNoTransitions,

		/// <summary>
		/// A state has no transitions
		/// </summary>
		ControllerStateNoTransition,

    /// <summary>
    /// A state appears several times in the 
    /// state list and/or as initial state
    /// </summary>
    ControllerMultipleStateDefinitions,

    /// <summary>
    /// A condition of a fsm controller
    /// tries to read from a datapath
    /// signal which has no well-defined value
    /// when the condition is beeing evaluated.
    /// </summary>
    FsmConditionReferencesSignal,

    /// <summary>
    /// A condition of a fsm controller
    /// tries to read from a datapath
    /// inport which has no well-defined value
    /// when the condition is beeing evaluated.
    /// </summary>
    FsmConditionReferencesInPort,

    /// <summary>
    /// A condition of a fsm controller
    /// tries to read from a datapath
    /// outport which has no well-defined value
    /// when the condition is beeing evaluated.
    /// </summary>
    FsmConditionReferencesOutPort,

    /// <summary>
    /// A reference to a nonexistent port
    /// on an ipblock or datapath is attempted
    /// </summary>
    SystemInvalidPort,

    /// <summary>
    /// System interconnect has multiple
    /// drivers
    /// </summary>
    SystemPortHasMultipleDrivers,

    /// <summary>
    /// System references unknown datapath or ipblock
    /// </summary>
    SystemUnknownDatapathOrIpBlock,


    /// <summary>
    /// Datapath has no controller attached
    /// </summary>
    DatapathNoController,

    /// <summary>
    /// The identifier referenced by expression
    /// could not be found 
    /// </summary>
    ExpressionInvalidIdentifier,

		/// <summary>
		/// The value could not be converted into an 
		/// integer.
		/// </summary>
		ExpressionInvalidIntegerValue,

    /// <summary>
    /// The left side of an assignment expression
    /// was not assignable
    /// </summary>
    ExpressionLeftHandSideNotAssignable,

    /// <summary>
    /// Assignment signal appeared outside sfg (in fsm, trace, $display?)
    /// </summary>
    ExpressionAssignmentOutsideSfg,

    /// <summary>
    /// Identifier not defined
    /// </summary>
    UnknownIdentifier,

		/// <summary>
		/// A clone statement has unknown datapath
		/// </summary>
		CloneUnknownDatapath,

    /// <summary>
    /// two or more tracers used the same destination file
    /// </summary>
    MultipleUsesOfTracerFile,

    /// <summary>
    /// Missing type information for ip block
    /// </summary>
    IpBlockNoType,

    /// <summary>
    /// Given a name cannot find datapath or ipblock
    /// </summary>
    NoSuchDatapathOrIpBlock,

    /// <summary>
    /// Errors regarding the port list of child datapaths
    /// </summary>
    ChildDatapathPortListError,

    /// <summary>
    /// Errors concerning the lookup tab () syntax
    /// </summary>
    LookupIndexError,

    /// <summary>
    /// an expression of the form a = b = c;
    /// </summary>
    DoubleAssignment
  }
}
